<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>首页</title>
    <include file="Pub:Style" />
    <style>
        .changelist {
            height: 75px;
            /* border: 1px solid #dcdcdc; */
            border-radius: 10px;
            text-align: center;
        }
    </style>
</head>
<body>
    <include file="Pub:head"/>
    <include file="Pub:search" />
    <div class="container">
        <div class="jumbotron" style="margin-bottom:0">
            <div id="myCarousel" class="carousel slide">
                <ol class="carousel-indicators">
                    <li data-target="#myCarousel" data-slide="0" class="active"></li>
                    <li data-target="#myCarousel" data-slide="1"></li>
                    <li data-target="#myCarousel" data-slide="2"></li>
                </ol>
                <div class="carousel-inner">
                    <div class="item active">
                        <img src="__PUBLIC__/img/zuoye1.png" alt="First slide">
                    </div>
                    <div class="item">
                        <img src="__PUBLIC__/img/zuoye1.png" alt="First slide">
                    </div>
                    <div class="item">
                        <img src="__PUBLIC__/img/zuoye1.png" alt="First slide">
                    </div>
                </div>
                <a href="#myCarousel" class="carousel-control left" data-slide="prev">
                    <span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
                </a>
                <a href="#myCarousel" class="carousel-control right" data-slide="next">
                    <span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
                </a>
            </div>
        </div>
    </div>
    <div class="container">
        <div class="row" style="margin-left:0;margin-right:0;">
            <div class="col-xs-3">
                <div class="changelist" onclick="javascript:window.location.href='__MODULE__/Index/goodslist?family=58'">
                    <img src="__PUBLIC__/img/bendi.png" alt="First slide" style="width:98%;">
                    <span>同城商品</span>
                </div>
            </div>
            <div class="col-xs-3">
                <div class="changelist" onclick="javascript:window.location.href='__MODULE__/User/score'">
                    <img src="__PUBLIC__/img/jifen.png" alt="First slide" style="width:98%;">
                    我的积分
                </div>
            </div>
            <div class="col-xs-3">
                <div class="changelist" onclick="javascript:window.location.href='__MODULE__/Index/goodslist?family=555'">
                    <img src="__PUBLIC__/img/remai.png" alt="First slide" style="width:98%;">
                    热卖商品
                </div>
            </div>
            <div class="col-xs-3">
                <div class="changelist" onclick="javascript:window.location.href='__MODULE__/Goods/goodsmenu'">
                    <img src="__PUBLIC__/img/fenlei.png" alt="First slide" style="width:98%;">
                    商品分类
                </div>
            </div>
        </div>
    </div>
    <div class="container" style="margin-bottom:75px;">
        <volist name="goodslist" id="vo">
            <div class="col-xs-6">
                <div class="goodslist" onclick="todetails(<#$vo.id#>)">
                    <!-- <input type="hidden" name="gid" value="<#$vo.id#>" id="gid"> -->
                    <div class="goodsimg">
                        <img id="gimg" src="__PUBLIC__/img/shili1.jpg" style="width:100%">
                        <input type="hidden" id="gg" value="<#$vo.g_img#>">
                        <script>
                            var imgstr = $("#gg").val();
                            var imgarr = imgstr.split(" ");
                            var img = $("#gimg");
                            img.attr('src',imgarr[1]);
                        </script>
                    </div>
                    <div class="info">
                        <div class="info_top">
                            <#$vo.g_name#>
                        </div>
                        <div class="info_mid">
                            <#$vo.g_price#>
                        </div>
                        <div class="info_bottom">
                            <img src="__PUBLIC__/img/toxiang.png" alt=""> <#$vo.u_nickname#>
                        </div>
                    </div>
                </div>
            </div>
        </volist>
        <div class="con_footer col-xs-12">
            到底了
        </div>
    </div>
    <include file="Pub:footer" />
</body>
<script>
    // 点击商品跳转到详情页
    function todetails(gid){
        // console.log(gid);
        document.location.href="__MODULE__/Goods/details?gid="+gid;
    }
</script>
</html>